package com.zx.mes.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.zx.mes.service.HelloService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * hello controller
 *
 * @author 华云龙
 * @date 2018-9-20
 */
@RestController
public class HelloController {

    /**
     * 非注册中心写法
     *
     * @Reference(url = "dubbo://10.30.90.136:20880")
     */
    @Reference
    private HelloService helloService;

    @GetMapping("/say")
    public String say(String message) {
        return helloService.say(message);
    }
}
